<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ include file="/base/base.jsp"%>
<%@ include file="/base/database.jsp" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport"
	content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<meta name="renderer" content="webkit">
<title>浏览请假信息</title>
<link rel="stylesheet" href="css/pintuer.css">
<link rel="stylesheet" href="css/admin.css">
<link rel="shortcut icon" href="images/logo.jpg">
<script src="js/jquery.js"></script>
<script src="js/pintuer.js"></script>

</head>

<body>

  <div class="panel admin-panel">
    <div class="panel-head"><strong class="icon-reorder"> 浏览请假信息</strong> </div>
    <div class="padding border-bottom">
      <ul class="search" style="padding-left:10px;">
       <li><select name="che" onchange="window.location=this.value">
        <option>选择学期</option>
        <option value="leave_term1.jsp">2018-2019</option>
        <option value="leave_term2.jsp">2019-2020</option>
       </select></li>
       <li><select name="che1" onchange="window.location=this.value">
        <option>选择班级</option>
        <option value="leave_class5.jsp">17软件工程5班</option>
        <option value="leave_class6.jsp">17软件工程6班</option>
       </select></li>

     
      </ul>
    </div>
    <table class="table table-hover text-center">
      <tr>
      		    <th>序号</th>
      		    <th>班级</th>
				<th>请假编号</th>
				<th>课程编号</th>
				<th>请假事由</th>
				<th>天数</th>
				<th>学号</th>
				<th>请假时间</th>
				<th>审核时间</th>
				<th>审核意见</th>
				<th>状态</th>
				
      </tr>
    
				
				
			
			<%  
			    request.setCharacterEncoding("utf-8");
			 
			    String  keyword=request.getParameter("keyword");
			
				StringBuffer sqlBuff = new StringBuffer();
				sqlBuff.append("select * from sys_leave where classID='17软件工程6班'");
				String sql = sqlBuff.toString();
		
				Connection conn = getConn();
			
				PreparedStatement pstmt = conn.prepareStatement(sql);

				
				ResultSet rs = pstmt.executeQuery();
				
				int index = 1;
				
				while (rs.next()) {
				
				String classID=rs.getString("classID");
				String leaveID=rs.getString("leaveID");
				String courseID=rs.getString("courseID");
				String reason =rs.getString("reason");
				String daynum =rs.getString("daynum");
				String stuNo=rs.getString("stuNo");
				String applytime=rs.getString("applytime");
				String audittime =rs.getString("audittime");
				String opinion =rs.getString("opinion");
				String status =rs.getString("status");
				
		
			%>

			<tr>
				 <td><%=index++ %></td>
				  <td><%=classID %></td>
				 <td><%=leaveID %></td>
				<td><%=courseID %></td>
				<td><%=reason %></td>
				<td><%=daynum %></td>
				<td><%=stuNo %></td>
				<td><%=applytime %></td>
				<td><%=audittime %></td>
				<td><%=opinion %></td>
				<td><%=status %></td>
				
				
			</tr>
			<%
				}
			%>
    </table>
    <div class="button-group">
	 <a class="button border-main" href="<%=path%>/export/testExcel.jsp?"><span class="icon-edit"></span>立即将其全部导出</a></div>
  </div>
  </div>
</body>
</html>
